<template>
  <div class="album-item">
    <div class="left">
      <img :src="item.blurPicUrl" alt="" />
    </div>

    <div class="right">
      <div class="top e_1">{{ item.name }}</div>

      <div class="bottom">
        <span v-for="ar in item.artists" :key="ar.id">{{ ar.name }}</span>
        {{ item.publishTime | formatDate }}
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    item: Object,
  },
  name: "AlbumItem",
};
</script>

<style lang="less" scoped>
.album-item {
  width: 95%;
  height: 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;

  .left {
    width: 40px;
    height: 100%;

    img {
      border-radius: 10px;
    }
  }

  .right {
    flex: 1;
    margin-left: 20px;

    .bottom {
      font-size: 13px;
      color: #707070;

      span {
        &::after {
          content: "/";
        }

        &:last-of-type {
          &::after {
            content: "";
          }
        }
      }
    }
  }

  &:last-of-type {
    margin-bottom: 0;
  }
}
</style>